package com.junhong.service.impl;

import java.io.Serializable;
import java.util.List;

import javax.annotation.Resource;
import javax.transaction.Transactional;

import org.springframework.stereotype.Service;

import com.junhong.dao.RoleDao;
import com.junhong.entity.Role;
import com.junhong.service.RoleService;
@Transactional
@Service("roleService")
public class RoleServiceImpl implements RoleService {
	@Resource
	private RoleDao roleDao;
	@Override
	public void add(Role role) {
		roleDao.add(role);
	}

	@Override
	public void update(Role role) {
		roleDao.update(role);
	}

	@Override
	public void delete(Role role) {
		roleDao.delete(role);
	}

	@Override
	public List<Role> find() {
		return roleDao.find();
	}

	@Override
	public List<Role> find(Integer pos, Integer rows) {
		return roleDao.find(pos, rows);
	}

	@Override
	public Role getById(Serializable id) {
		return roleDao.getById(id);
	}

	@Override
	public long count() {
		return roleDao.count();
	}

}
